import ReactMarkdown from 'react-markdown'
import MdEditor from 'react-markdown-editor-lite';
// import style manually
import 'react-markdown-editor-lite/lib/index.css';
const Com = () => {
    
    return (
        <div>
            <h1>MarkDown</h1>
            <MdEditor style={{ height: '500px' }} 
            renderHTML={ text => {
                return (
                    <ReactMarkdown>
                        {text}
                    </ReactMarkdown>
                )
            }} 
            onChange={({html, text}) => {
                console.log('handleEditorChange', html, text);
            }
            }>

            </MdEditor>
            {/* renderHTML={text => mdParser.render(text)}  */}
        </div>
    )
}

export default Com